package com.test.clyq.serviceImpl;

import java.util.List;

import com.test.clyq.dao.UsersDao;
import com.test.clyq.entity.Users;
import com.test.clyq.service.UserService;
import com.test.service.impl.BaseManager;
import com.test.util.Pagination;

/**
 * UserServiceImpl. <br>
 * 用户信息管理.
 * <p>
 * Copyright: Copyright (c) 2010-4-19 下午04:47:55
 * <p>
 * Company: 北京宽连十方数字技术有限公司
 * <p>
 * Author: liuxl@c-platform.com
 * <p>
 * Version: 1.0
 * <p>
 */
@SuppressWarnings("unchecked")
public class UserServiceImpl extends BaseManager implements UserService {

	private UsersDao userDao;

	public void setUserDao(UsersDao userDao) {
		this.userDao = userDao;
	}

	public void addUser(Users user) {
		this.userDao.addUser(user);
	}

	public boolean delUsersById(Long id, Users NLUsers) {
		return this.userDao.delUsersById(id, NLUsers);
	}

	public List<Users> getUsers() {
		return this.userDao.getUsers();
	}

	public Users getUsersById(Long id) {
		return this.userDao.getUsersById(id);
	}

	public Users getUsersByNameAndPwd(String name, String pwd) {
		return this.userDao.getUsersByNameAndPwd(name, pwd);
	}

	public void saveOrUpdate(Users user) {
		this.userDao.saveOrUpdate(user);
	}

	public List<Users> userList(Pagination pagination) {
		return this.userDao.userList(pagination);
	}

}
